Tom,
I am struggling to make sense of the control of the above.
I am pretty sure it is a comprehension issue having tried another kflop.
The VFD supplies 5V, I put this into JP33 Pin5, and Ground from the VFD into Pin7. But Pin 6 is reading 0V.
I have the code from usingkstep page:
FPGA(KAN_TRIG_REG)=4; // Mux PWM0 to JP7 Pin5 IO 44 for KSTEP
SetBitDirection(44,1); // define bit as an output
FPGA(IO_PWMS_PRESCALE) = 46; // divide clock by 46 (1.4 KHz)
FPGA(IO_PWMS+1) = 1; // Enable
I have found two PWM commands that seem like they might be relevant, WritePWM(a,b) and PWMa=b.
The range for these commands would seem to be -255 -> +255 so I was hoping that PWM0=0 would result in something between 0 and 5V as an output on pin 6.
PWM0=255 should be give closer to 5V and PWM0=-255 should give closer to 0V.
This does not seem to be the case, I get a solid, stable and reliable 0V on pin 6.
Once I have some control of the VFD speed.. I wish to use CSS so would like to use the Spindle.c programs but none of these seemed to want to help my comprehension either as none of them refer to PWM.
I look forward as always to your response and being put on the right track :)
Many thanks,
Jon